package com.itheima.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author Andy
 * @Description //TODO HelloWorldController
 * @Date 2022/3/22 11:46 上午
 * @Version 1.0
 **/
@RestController
@RequestMapping("/hello")
public class HelloWorldController {

    private static int count = 0;

    @GetMapping("")
    public String hello(){
        String s = "hello api invoke " + (count++) + " times";
        System.out.println(s);
        return s;
    }
}
